{{ $root := site.Params.social.github_repo }}
{{ $source := printf "https://github.com/%s/tree/master/website/content/%s/%s" $root .Lang .File.Path }}
{{ $edit := printf "https://github.com/%s/edit/master/website/content/%s/%s" $root .Lang .File.Path }}
<div class="flex space-x-1 text-xs">
  <a href="{{ $source }}" class="py-1 px-2 rounded bg-gray-700 text-white dark:bg-gray-500 hover:bg-black dark:hover:bg-gray-600 shadow flex items-center space-x-1.5" rel="noopener" target="_blank">
    <ion-icon name="logo-github" class="text-white"></ion-icon>

    <span>
      Page source
    </span>
  </a>

  <a href="{{ $edit }}" class="py-1 px-2 rounded bg-gray-700 text-white dark:bg-gray-500 hover:bg-black dark:hover:bg-gray-600 shadow flex items-center space-x-1.5" rel="noopener" target="_blank">
    <ion-icon name="logo-github" class="text-white"></ion-icon>

    <span>
      Edit this page
    </span>
  </a>
</div>